package com.app.pojo;

import com.app.util.Result;
import com.baomidou.mybatisplus.annotation.*;

import java.time.LocalDateTime;
import java.io.Serializable;

import com.fasterxml.jackson.annotation.JsonFormat;
import lombok.Data;
import lombok.EqualsAndHashCode;

/**
 * <p>
 * 信息公告
 * </p>
 *
 * @author yoominic
 * @since 2024-07-29
 */
@Data
@EqualsAndHashCode(callSuper = false)
@TableName("tb_public_announcement")
public class PublicAnnouncement implements Serializable {

    private static final long serialVersionUID = 1L;

    /**
     * 公告ID
     */
    @TableId(value = "id", type = IdType.AUTO)
    private Integer id;

    /**
     * 公告封面
     */
    private String cover;

    /**
     * 标题
     */
    private String title;

    /**
     * 内容
     */
    private String content;

    /**
     * 状态 1正常 0作废
     */
    private Integer status;

    /**
     * 浏览次数
     */
    private Integer viewsNumber;

    /**
     * 创建人
     */
    private Integer createUser;

    /**
     * 创建时间
     */
    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private LocalDateTime createTime;

    @TableField(exist = false)
    private String createTimeStr;
    @TableField(exist = false)
    private String updateTimeStr;

    /**
     * 创建人
     */
    private Integer updateUser;

    @JsonFormat(pattern = "yyyy-MM-dd HH:mm", timezone = "GMT+8")
    private LocalDateTime updateTime;
    /**
     * 1公告 2通知
     */
    private Integer type;

    private transient String createUserName;


}
